package strings;

import java.util.*;

public class Receipt{
    private double total = 0;
    private static int LEN = 5;
    private Formatter f = new Formatter(System.out);
    public void printTitle(){
        String str = String.format("%-%ds %%ds %%ds\n",3*LEN,LEN,2*LEN);
        f.format(str, "Item", "Qty", "Price");
    }

    public static void main(String[] args){
        Receipt receipt = new Receipt();
        receipt.printTitle();
    }
}
